package com.heifei.day02

/**
 * @author caizhengjun
 * @date 2020/8/4 8:24 下午
 */
class Teacher(val name: String,
              var age: Int,
              var fv: Double,
              private var email: String = "caizhengjun01@gmail.com",
              private[this] var password: String = "password") {

  private[this] def printPassword(): String = {
    println(this.password)
    password
  }
}

object Teacher {

  def main(args: Array[String]): Unit = {
    val teacher: Teacher = new Teacher("蔡正峻", 26, 9999.99)
    println(teacher.email)
    //teacher.printPassword()
  }
}
